Java standards for web services are constantly being developed. Concurrently, businesses are building important applications on top of web services infrastructures, such as that available in WebLogic Server from BEA Systems of San Jose, Calif. As these applications evolve, they become more complex with more operations to perform.
A prior art system illustrating a client-server system is illustrated in FIG. 1. A typical web service 135 residing on a server 130 may be accessed by a client 120. The client may be implemented as a stand alone machine that communicates with the server over a physical connection or a logically implemented client that resides on the same machine as the server. If implemented on a stand alone machine, the client includes a processor 121, RAM 122, input means 123 and output means 124. In either embodiment, the client is configured to include vendor-added application code 125 as well as standard JAVA objects such as client web service applications 126 such as client web service Runtime. The server 130 includes a web service 135. A user may invoke the web service 135 through the client 120.
FIG. 2 illustrates a method 200 for invoking a web service in accordance with one embodiment of the present invention. Operation of method 200 begins with start step 205. Application code requests a web service at step 210. In one embodiment, application code residing within the client initiates a call to the client's runtime routine to request a web service residing on a server. This may be initiated by a user or other code within the client. Next, the client invokes the web service on the server in step 220. The invocation request initiates the generation of an application thread by runtime in which the request is carried out. The server receives the request and processes the request at step 230. Next, the server returns a result to the client at step 240. The client receives the result in step 250 and provides the application code with the result at step 260. The thread is then complete and operation of method 200 then ends at step 265. Throughout steps 220-260, the synchronized operation initiated by the application code is performed within a single thread. Thus, the synchronized operation involves the application code waiting for a response from the client before performing other tasks. Thus, the thread is blocked until the web service invoke is complete. An Enterprise Java Bean (EJB) does not allow application code to create new threads. As a result, the method currently used by client server systems to process user requests is slow and inefficient.
What is needed is a web service invocation model that allows a user to perform other tasks while a request is being processed.